package GA;

import instrumentation.Condition;

import java.util.Map;

import ReadWriteFieldsRelations.MethodRelations;
import random.TestClusterBuilder;

public class GAInfo {
	private long testTimeout;
	private long startTime;
	private Chromosome[] population;
	private int          generation;
	private float          populationFitness;
	private float          lastBestFitness;
	private int          noImprovementCount;
	private int          noExecution=0;
	private 			TestClusterBuilder TestCluster;
	private MethodRelations relations;
	Map<Integer, Condition> mapBranchCondition;
	private int attempt=1;

	public void setMethodRelations(MethodRelations relations){
		this.relations=relations;
	}
	public MethodRelations getMethodRelations(){
		return this.relations;
	}
	public void setMapBranchCondition(Map<Integer, Condition> mapBranchCondition){
		this.mapBranchCondition=mapBranchCondition;
	}
	public Map<Integer, Condition>  getMapBranchCondition(){
		return this.mapBranchCondition;
	}

	public long getTestTimeOut() {
		return testTimeout;
	}
	public void setTestTimeOut(long testTimeout) {
		this.testTimeout = testTimeout;
	}
	public long getStartTime() {
		return startTime;
	}
	public void setStartTime(long startTime) {
		this.startTime = startTime;
	}

	public int getAttempt() {
		return attempt;
	}
	public void setAttempt(int attempt) {
		this.attempt = attempt;
	}
	public int getNoExecution() {
		return this.noExecution;
	}
	public void setNoExecution(int noExecution) {
		this.noExecution = noExecution;
	}

	
	public Chromosome[] getPopulation() {
		return population;
	}
	public void setPopulation(Chromosome[] population) {
		this.population = population;
	}
	public void setTestCluster(TestClusterBuilder TestCluster){
		this.TestCluster= TestCluster;
	}
	public TestClusterBuilder getTestCluster(){
		return this.TestCluster;
	}

	public int getGeneration() {
		return generation;
	}
	public void setGeneration(int generation) {
		this.generation = generation;
	}
	
	public float getPopulationFitness() {
		return populationFitness;
	}
	public void setPopulationFitness(float populationFitness) {
		this.populationFitness = populationFitness;
	}
	

	
	public float getLastBestFitness() {
		return lastBestFitness;
	}
	public	void setLastBestFitness(float lastBestFitness) {
		this.lastBestFitness = lastBestFitness;
	}
	
	public int getNoImprovementCount() {
		return noImprovementCount;
	}
	public	void setNoImprovementCount(int noImprovementCount) {
		this.noImprovementCount = noImprovementCount;
	}
	
}
